insert
overwrite
table
jms_dwd.dwd_abnormal_event_hi
partition
(
dt
)
select id
       ,title
       ,description
       ,current_node_names
       ,status
       ,code
       ,abnormal_type_id
       ,category
       ,type
       ,name
       ,level
       ,involved_org_code
       ,involved_org_name
       ,involved_agent_code
       ,involved_agent_name
       ,is_defer
       ,defer_day
       ,defer_end_time
       ,defer_agent_code
       ,defer_agent_name
       ,file_url
       ,is_warning
       ,happen_time
       ,find_time
       ,is_foreign_related
       ,foreign_related_org_name
       ,create_by
       ,update_by
       ,create_by_name
       ,update_by_name
       ,create_time
       ,update_time
       ,create_by_phone
       ,reject_time
       ,employee_code
       ,employee_name
       ,hire_date
       ,employee_attribute
       ,accident_type
       ,date_of_injury
       ,company_compensate
       ,insurance_compensate
       ,outsourcing_compensate
       ,total_compensate
       ,over_date
       ,is_injury
       ,insurance_type
       ,push_flag
       ,'{{ execution_date | cst_ds }}' as dt
from   jms_ods.abnormal_event_hi
   where dt = '{{ execution_date | cst_hour }}';